package com.gelsanalyzer.mvc.model;

import java.beans.*;

/**
 * This interface is intended to provide a solid base from which to implement
 * our MVC architecture. It was inspired from the article <a
 * href="http://java.sun.com/developer/technicalArticles/javase/mvc/">Java SE
 * Application Design With MVC</a>
 * 
 * @author Jared Olhoft
 */
public interface IModel {
    /**
     * This method should add a property change listener to the private
     * collection of observers that should exist in the implementing class.
     * 
     * @param listener The property change listener
     */
    public void addPropertyChangeListner(PropertyChangeListener listener);

    /**
     * This method should removes a property change listener from the collection
     * of observers that should exist in the implementing class.
     * 
     * @param listener The property change listener
     */
    public void removePropertyChangeListener(PropertyChangeListener listener);

//    /**
//     * Fires an event to all registered listeners informing them that a property
//     * in this model has changed.
//     * 
//     * @param propertyName The name of the property
//     * @param oldValue The previous value of the property before the change
//     * @param newValue The new property value after the change
//     */
//    abstract void firePropertyChange(String propertyName,
//                                     Object oldValue,
//                                     Object newValue);
}
